home *** CD-ROM | disk | FTP | other *** search
- global gDBPicttextVarList
-
- on InitButtons EnableScroll
- MyObj = getaProp(gDBPicttextVarList, GetObjProp())
- SaveObj = GetSaveObj(MyObj)
- ButtonList = GetButtonList(MyObj)
- SpList = GetSpriteList(MyObj)
- cbs = getaProp(SpList, #closeBox)
- mmbs = getaProp(SpList, #MaxMinBox)
- CopyBS = getaProp(SpList, #CopyButton)
- PrintBS = getaProp(SpList, #PrintButton)
- SaveBS = getaProp(SpList, #SaveButton)
- addProp(ButtonList, cbs, new(script("close box"), "close box", "global", cbs, the loc of sprite cbs))
- addProp(ButtonList, mmbs, new(script("max min box"), "min max", "global", mmbs, the loc of sprite mmbs))
- addProp(ButtonList, CopyBS, new(script("copy icon"), "copy", "internal", CopyBS, the loc of sprite CopyBS))
- addProp(ButtonList, PrintBS, new(script("print icon"), "print", "internal", PrintBS, the loc of sprite PrintBS))
- addProp(ButtonList, SaveBS, new(script("save icon"), "save", "internal", SaveBS, the loc of sprite SaveBS))
- b1 = 28
- b2 = 29
- b3 = 30
- b4 = 31
- addProp(ButtonList, b1, new(script("save text"), "savetext", "internal", b1, point(143, 104)))
- addProp(ButtonList, b2, new(script("save picture"), "savepic", "internal", b2, point(143, 134)))
- addProp(ButtonList, b3, new(script("save both"), "saveboth", "internal", b3, point(144, 170)))
- addProp(ButtonList, b4, new(script("save cancel"), "savecancel", "internal", b4, point(144, 170)))
- repeat with rc in ButtonList
- Inscope(rc)
- end repeat
- disable(getaProp(ButtonList, CopyBS))
- SetButtonList(MyObj, ButtonList)
- EvalDisableScroll(EnableScroll)
- repeat with rc in [cbs, mmbs, PrintBS, SaveBS]
- set the cursor of sprite rc to GetPointingCursor(MyObj)
- end repeat
- end
-
- on EvalDisableScroll EnableScroll
- MyObj = getaProp(gDBPicttextVarList, GetObjProp())
- ButtonList = GetButtonList(MyObj)
- SpList = GetSpriteList(MyObj)
- vbs = getaProp(SpList, #VBed)
- nas = getaProp(SpList, #NArrow)
- sas = getaProp(SpList, #SArrow)
- vts = getaProp(SpList, #VThumb)
- repeat with rc in [vbs, nas, sas, vts]
- if EnableScroll then
- Inscope(getaProp(ButtonList, rc))
- next repeat
- end if
- disable(getaProp(ButtonList, rc))
- end repeat
- end
-